Domain Coloring

A function of real numbers y = f(x) can be represented graphically using the
familiar Cartesian coordinates on the x/y plane. But representing a complex
function w = f(z) requires 4 dimensions: 2 for the domain z = zx + zyi and 2
for the range w = wx + wyi. One convenient way to do this is to use domain
coloring. In this process, selected points on the z plane are located using
the horizontal axis for zx and the vertical axis for zyi. The points are
calculated, yielding wx and wyi. Those points are assigned the color of their
position on the w plane, which is a color map, and are plotted at the position
zx + zyi.

Typically the color map on the w plane consists of some form of HSV gradient.
This is convenient because the Hue can be assigned to the argument of w (the
angle it makes with the origin). The Value can be assigned to the modulus of
w (its absolute value). In the simplest schemes, the Saturation can be held
at a constant 1.0. Various cyclic modifications of this scheme can be used.

However, any image can be used as a color map, even a digital photograph.

Iterated escape-time fractals (e.g. Mandelbrot and Julia sets) also are
rendered by evaluating points on the z plane. But then, only a third dimension
is plotted, which typically represents the iteration count for escaping points
and either a solid color or some form of orbit trap for points which do not
escape.

Similarly, instead of using domain coloring, a complex function can be
represented by assigning a color value to its modulus as a third dimension. If
the color palette is a grey scale, the resulting image can be used as a height
field to create a simulated 3-dimensional image using ray tracing or similar
rendering techniques.